<template>
  <a-layout >
    <div>
      <a-button type="primary" @click="getBack">返回列表</a-button>
    </div>
    <a-tabs defaultActiveKey="1" v-model="activeKey" >
      <a-tab-pane tab="收货明细" key="1">
        <receive-detail ref="receiveDetail"></receive-detail>
      </a-tab-pane>
      <a-tab-pane tab="批属性" key="2" forceRender>
        <lot-property></lot-property>
      </a-tab-pane>
      <a-tab-pane tab="质检结果" key="3" forceRender>
        <inspect-result></inspect-result>
      </a-tab-pane>
      <a-tab-pane tab="销退" key="4" forceRender>
        <sale-return></sale-return>
      </a-tab-pane>
      <a-tab-pane tab="收货箱明细" key="5" forceRender>
        <receive-box-detail></receive-box-detail>
      </a-tab-pane>
      <a-tab-pane tab="收货重量信息" key="6" forceRender>
        <receive-weight-info></receive-weight-info>
      </a-tab-pane>
    </a-tabs>
  </a-layout>
</template>

<script>
import ReceiveDetail from '@/views/editPreview/ReceiveDetail'
import LotProperty from '@/views/editPreview/LotProperty'
import InspectResult from '@/views/editPreview/InspectResult'
import SaleReturn from '@/views/editPreview/SaleReturn'
import ReceiveBoxDetail from '@/views/editPreview/ReceiveBoxDetail'
import ReceiveWeightInfo from '@/views/editPreview/ReceiveWeightInfo'
export default {
  name: 'Edit',
  components: { ReceiveWeightInfo, ReceiveBoxDetail, SaleReturn, InspectResult, LotProperty, ReceiveDetail },
  data () {
    return {
      activeKey: '1'
    }
  },
  methods: {
    getBack () {
      this.$emit('getBack')
    },
    setFormValue (record) {
      this.$refs.receiveDetail.setFormValue(record)
    }
  }
  // watch: {
  //   params () {
  //     this.$message.info(JSON.stringify(this.params))
  //   }
  // },
  // mounted () {
  //   this.$message.info(JSON.stringify(this.params))
  // }
}
</script>
